home *** CD-ROM | disk | FTP | other *** search
/ Aminet 1 (Walnut Creek) / Aminet - June 1993 [Walnut Creek].iso / aminet / text / misc / ht.lha / hypertext / Dme / setup.edrc < prev   
Text File  |  1990-12-23  |  2KB  |  62 lines

  1. #    The following macros are designed to be used from within DME when
  2. # creating documents for HT.  Their purpose is to make life a little
  3. # easier and faster.  Just source this file when you want to work on
  4. # HT documents (and also make sure that REXX will be able to find the
  5. # dme macros).
  6. #
  7. #    I used "alt" based keymappings because I figured they wouldn't
  8. # conflict with keymaps you already have.
  9. #    Feel free to change the keymappings as you see fit.  I thought they
  10. # made sense, maybe you don't.
  11. #
  12. # D.B.G. July 1990
  13.  
  14. # The "test macro".  It will save the current filename, then call an
  15. # Arexx macro to load this file directly into HT
  16. #
  17. map a-t (saveold rx1 test \$filename)
  18. # for ease of typing, we'll add this too.
  19. map c-t (a-t)
  20.  
  21. # These (tiny) macros are setup to insert the necessary text to turn
  22. # on (and off) the specified attributes.
  23. #   Oh, BTW - all the backslashes *are* necessary ;-(
  24. map a-b ( `\\\\BOLD ' )
  25. map a-i ( `\\\\ITALIC ' )
  26. map a-u ( `\\\\UNDERLINE ' )
  27.  
  28. #   And the two biggie macros.... these handle creating a link in your
  29. # document.  Since DME doesn't do char based highlighting/blocking we
  30. # have to do a Start link (a-s) to know exactly where to start the link
  31. # and then the actual LINK macro which will call an Arexx macro to
  32. # pop up a window which you use to specify your link.  The Arexx macro
  33. # then inserts the appropriate text into your document at the right spots.
  34.  
  35. #
  36. #   The first macro is used to define where to START the link,
  37. # I have used text markers 8 and 9 pretty arbitrarily.    Change them
  38. # here and in link.dme if they conflict with what you use them for
  39. map a-s (ping 8)
  40.  
  41. # and the second macro actually makes the call...
  42. map a-l (ping 9 rx do_link)
  43.  
  44. # Here we add some menus to the window so that we can have some
  45. # user-friendliness... (ackk, cough, gasp ! user-friendly, what a horrible
  46. # word ;-)
  47. #
  48. # If you don't want this stuff, just comment it out - it doesn't do or
  49. # add anything extra.
  50.  
  51. menuoff
  52. menuadd HyperText `Bold on/off' (a-b)
  53. menuadd HyperText `Italics on/off' (a-i)
  54. menuadd HyperText `Underline on/off' (a-u)
  55. menuadd HyperText () (null)
  56. menuadd HyperText `Start Link' (a-s)
  57. menuadd HyperText `Define Link' (a-l)
  58. menuadd HyperText () (null)
  59. menuadd HyperText `Test current Document' (a-t)
  60. menuon
  61.  
  62.